<ion-header>
    <ion-toolbar content-page>
        <!--<ion-buttons start>-->
        <!--<button ion-button icon-only navPop>-->
        <!--<i class="back"></i>-->
        <!--</button>-->
        <!--</ion-buttons>-->
        <ion-title>
            <button class="nav-btn" (click)="popToActivityList()">活动</button>
            <button class="nav-btn nav-btn_active">名单</button>
        </ion-title>
        <ion-buttons end>
            <ion-buttons>
                <button ion-button icon-only adpmenutoggle>
                    <i class="toolbar-menu"></i>
                </button>
            </ion-buttons>
        </ion-buttons>
    </ion-toolbar>
</ion-header>
<div class="expand-modal2"  (click)="expandSelect()" [class.expand-modal_dis]="!isExpandSorter"></div>
<ion-content class="roster-scroll">
    <div class="switch-bar" ion-fixed>
        <div class="switch-btn" [class.switch-btn_selected]="currentView === 0" (click)="changeCurrentView(0)">客户名单
        </div>
        <div class="switch-btn" [class.switch-btn_selected]="currentView === 1" (click)="changeCurrentView(1)">增员名单
        </div>
        <span class="switch-sign" [class.sign-change]="currentView === 1"></span>
    </div>
    <div class="fixed-bar" ion-fixed>
        <span class="roster-num">共{{totalNum}}{{currentView === 0 ? '个客户': '个增员对象'}}</span>
        <div class="btn-wrapper">
            <button ion-button class="sort-btn" (click)="expandSelect()"><i></i>排序</button>
            <button ion-button class="filter-btn" (click)="goToRosterFilter()"><i></i>筛选</button>
            <button ion-button class="map-btn" *ngIf="currentView===0" (click)="goToRosterMap()"><i></i>地图</button>
        </div>
        <span class="expand-bar" modal-disscroll [class.expand-bar_open]="isExpandSorter"></span>
        <div class="expand-select" [class.expand-select_open]="isExpandSorter">
            <div class="expand-title">请选择排序方式</div>
            <div class="expand-option" *ngFor="let item of sortByList"
                 [class.expand-option_selected]="item.val === rosterFil.sortBy"
                 (click)="switchSotrBy(item.val)">{{item.label}}
            </div>
        </div>
    </div>
    <div class="expand-modal" (click)="expandSelect()" [class.expand-modal_dis]="!isExpandSorter"
         modal-disscroll></div>
    <div class="title-bar row" ion-fixed *ngIf="currentView === 0">
        <div class="col">姓名</div>
        <div class="col">活动名称</div>
        <div class="col">加保潜能</div>
        <div class="col">开始时间</div>
        <div class="col">跟进状态</div>
        <div class="col">通话</div>
    </div>
    <div class="title-bar2 row" ion-fixed *ngIf="currentView === 1">
        <div class="col">姓名</div>
        <div class="col">活动名称</div>
        <div class="col">参与时间</div>
        <div class="col">跟进状态</div>
        <div class="col">通话</div>
    </div>
    <div class="card-list roster-list-card" *ngIf="currentView === 0" [class.hide]="!isLoaded">
        <div *ngIf="rosterList && rosterList.length === 0 && isLoaded" class="no-data">
            <div class="no-data-img"><img src="./assets/images/common/icon_nodata.png"></div>
            <div class="no-data-txt">没有相关数据</div>
        </div>
        <roster-card *ngFor="let roster of rosterList; index as index"
                     class="card row" [isSingle]="false"
                     [classify]="0" [index]="index" [roster]="roster"
                     (showAction)="showSelectAction(roster.id, index, $event)"
                     (switchUserStatus)="switchUserStatus($event)"></roster-card>
    </div>
    <div class="card-list roster-list-card" *ngIf="currentView === 1" [class.hide]="!isLoaded">
        <div *ngIf="rosterList && rosterList.length === 0 && isLoaded" class="no-data">
            <div class="no-data-img"><img src="./assets/images/common/icon_nodata.png"></div>
            <div class="no-data-txt">没有相关数据</div>
        </div>
        <roster-card *ngFor="let roster of rosterList; index as index"
                     [classify]="1" [index]="index" [roster]="roster"
                     (showAction)="showSelectAction(roster.id, index, $event)"
                     class="card row"
                     (switchUserStatus)="switchUserStatus($event)"></roster-card>
    </div>
</ion-content>
